import re


def get_last_page_num():
    with open('../spider/get_list_info.log', encoding='utf8') as file:
        text = file.read()
    ans = re.findall('(?<=正在写入第)\d+(?=页)', text)
    if ans:
        return max(list(map(int, ans)))


print(get_last_page_num())
